<?php
 
//删除文章里的圖片
  include_once("./config.php");
  $id=$_GET['id'];
  $query_pic="select * FROM $TBL_ADV WHERE id=$id"; 
  $result = mysql_query($query_pic);
  if($row = @mysql_fetch_array($result))
  {
	$new_id = $row['NEW_ID'];
	$IMG_NAME = $row['img'];
	@unlink($conf['fck_upload'].'adv/'.$IMG_NAME); 
  }
  mysql_query("delete FROM $TBL_ADV WHERE id=$id");   
  MyNotice("廣告成功删除!",1,"news.php");  
  exit(0);
?>